import http from "@/utils/request";
//查询党员列表
export default {
    async getDymcList(pageNo, pageSize, approveStatus, startDate, endDate) {
        return await http.get("/api/yxglDymc/list", { pageNo, pageSize, approveStatus, startDate, endDate });
    },
    //新增党员
    async addDymc(params) {
        return await http.post("/api/dymc/add", params);
    },
    //编辑党员
    async updateDymc(params) {
        return await http.put("/api/dymc/update", params);
    },
    // //删除党员
    // async deleteDymc(params) {
    //     return await http.delete("/api/dymc/delete", params);
    // },
    //上传文件
    async importExcel(myfile) {
        console.log(29999999);
        console.log(myfile.get("myfile"));

        return await http.upload("/api/fileAbout/fileUpload", { myfile })
    },

    //导入文件
    async batchImportExcel(filePath) {
        console.log(typeof (filePath));
        console.log(filePath.get("filePath"));
        return await http.upload("/api/dymc/batchInput", { filePath })
    },
    //下载模板
    async download(params) {
        // console.log(1);
        return await http.get("/api/dymc/downLoadExcel", params)
    },
    //删除
    async delete(params) {
        return await http.delete('api/dymc/delete', params);

    },
    //批量删除
    async Bdelete(params) {
        return await http.post('/api/dymc/batchDelete', params);

    }
};